// com.cscec5b.inspection.config.SessionConfig
package com.cscec5b.inspection.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.session.web.http.HeaderHttpSessionIdResolver;
import org.springframework.session.web.http.HttpSessionIdResolver;

@Configuration
public class SessionConfig {
    @Bean
    public HttpSessionIdResolver httpSessionIdResolver() {
        // 会话ID来自请求头 X-Auth-Token
        return HeaderHttpSessionIdResolver.xAuthToken();
    }
}
